<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        #app {
            padding: 10px;
        }

        .searBox {
            width: 100%;
            display: flex;
            align-items: center;
            margin-top: 20px;
        }

        .searBox input {
            flex: 1;
            height: 40px;
            outline: none;
            border: none;
            padding-left: 20px;
            border-radius: 20px;
            background-color: rgb(245, 238, 238);
        }

        .searBox span {
            width: 60px;
            height: 40px;
            color: rgb(16, 176, 239);
            text-align: center;
            line-height: 40px;
        }

        .historySearch h3 {
            margin-top: 25px;
        }

        .historySearch span {
            display: inline-block;
            padding: 10px;
            margin-left: 10px;
            margin-top: 10px;
            background-color: rgb(245, 238, 238);
        }
    </style>
</head>

<body>
    <div id="app">
        <div>
            <h2>搜索</h2>
        </div>
        <div class="searBox">
            <input type="text" placeholder="搜索商家，商品名称" v-model="searchText">
            <span @click="search">搜索</span>
        </div>
        <div class="historySearch">
            <h3>历史搜索</h3>
            <span v-for="(item,index) in searchArr">{{item}}</span>
        </div>
        <div class="historySearch">
            <h3>搜索发现</h3>
            <span v-for="(item,index) in findArr">{{item}}</span>
        </div>

    </div>
    <script src="1.vue-2.5.21.js"></script>
    <script src="3.zuoye-搜索.js"></script>
</body>

</html>